<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pyopenspime.ssl.EnDec</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pyopenspime/">PyOpenSpime v0.2</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        Package&nbsp;pyopenspime ::
        <a href="pyopenspime.ssl-module.html">Module&nbsp;ssl</a> ::
        Class&nbsp;EnDec
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="pyopenspime.ssl.EnDec-class.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== CLASS DESCRIPTION ==================== -->
<h1 class="epydoc">Class EnDec</h1><p class="nomargin-top"><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec">source&nbsp;code</a></span></p>
<p>Encrypter-Decrypted object. This object is used to encrypt, descrypt 
  and sign OpenSpime stanzas. It includes RSA and AES support as defined in
  the OpenSpime Core Protocol v0.9.</p>

<!-- ==================== INSTANCE METHODS ==================== -->
<a name="section-InstanceMethods"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Instance Methods</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-InstanceMethods"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__init__"></a><span class="summary-sig-name">__init__</span>(<span class="summary-sig-arg">self</span>)</span><br />
      Initialize an EnDec object.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__init__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#load_rsa_key_bio" class="summary-sig-name">load_rsa_key_bio</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">rsa_pub_key_path</span>,
        <span class="summary-sig-arg">rsa_priv_key_path</span>,
        <span class="summary-sig-arg">rsa_priv_key_pass</span>)</span><br />
      Load public and private RSA key from .pem files.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_key_bio">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#load_rsa_pub_key" class="summary-sig-name">load_rsa_pub_key</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">rsa_pub_key_path</span>)</span><br />
      Load public RSA key from .pem file.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_pub_key">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#load_rsa_priv_key" class="summary-sig-name">load_rsa_priv_key</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">rsa_priv_key_path</span>,
        <span class="summary-sig-arg">rsa_priv_key_pass</span>)</span><br />
      Load private RSA key from .pem file.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_priv_key">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__rsa_callback_get_passphrase"></a><span class="summary-sig-name">__rsa_callback_get_passphrase</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">v</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__rsa_callback_get_passphrase">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__aes_encrypt_base64"></a><span class="summary-sig-name">__aes_encrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">plaintext</span>,
        <span class="summary-sig-arg">aes_key</span>,
        <span class="summary-sig-arg">aes_vint</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__aes_encrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__aes_decrypt_base64"></a><span class="summary-sig-name">__aes_decrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">encrypted</span>,
        <span class="summary-sig-arg">aes_key</span>,
        <span class="summary-sig-arg">aes_vint</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__aes_decrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__rsa_public_encrypt_base64"></a><span class="summary-sig-name">__rsa_public_encrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">plaintext</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__rsa_public_encrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__rsa_private_decrypt_base64"></a><span class="summary-sig-name">__rsa_private_decrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">encrypted</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__rsa_private_decrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__rsa_private_encrypt_base64"></a><span class="summary-sig-name">__rsa_private_encrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">plaintext</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__rsa_private_encrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr class="private">
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a name="__rsa_public_decrypt_base64"></a><span class="summary-sig-name">__rsa_public_decrypt_base64</span>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">encrypted</span>)</span></td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.__rsa_public_decrypt_base64">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">str</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#private_encrypt_text" class="summary-sig-name">private_encrypt_text</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">plaintext</span>)</span><br />
      Encrypts plaintext with the RSA private key of entity.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_encrypt_text">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">tuple</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#public_encrypt" class="summary-sig-name">public_encrypt</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">transport</span>)</span><br />
      Encrypts the content of the transport node with public key of 
      recipient.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.public_encrypt">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">str</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#private_decrypt" class="summary-sig-name">private_decrypt</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">encrypted</span>,
        <span class="summary-sig-arg">transport_key_enc</span>)</span><br />
      Decrypts a string encoded with public key of recipient.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_decrypt">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">str</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#private_sign" class="summary-sig-name">private_sign</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">content</span>)</span><br />
      Returns the value of the signature of a the &lt;transport/&gt; node.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_sign">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">boolean</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.ssl.EnDec-class.html#public_check_sign" class="summary-sig-name">public_check_sign</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">content</span>,
        <span class="summary-sig-arg">signature</span>)</span><br />
      Returns the value of the signature of a the &lt;transport/&gt; node.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.public_check_sign">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<!-- ==================== METHOD DETAILS ==================== -->
<a name="section-MethodDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Method Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-MethodDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="load_rsa_key_bio"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">load_rsa_key_bio</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">rsa_pub_key_path</span>,
        <span class="sig-arg">rsa_priv_key_path</span>,
        <span class="sig-arg">rsa_priv_key_pass</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_key_bio">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Load public and private RSA key from .pem files.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>rsa_pub_key_path</code></strong> (unicode) - The path to the RSA public key .pem file.</li>
        <li><strong class="pname"><code>rsa_priv_key_path</code></strong> (unicode) - The path to the RSA private key .pem file.</li>
        <li><strong class="pname"><code>rsa_priv_key_pass</code></strong> (unicode) - The RSA private key .pem file password.</li>
    </ul></dd>
  </dl>
</td></tr></table>
</div>
<a name="load_rsa_pub_key"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">load_rsa_pub_key</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">rsa_pub_key_path</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_pub_key">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Load public RSA key from .pem file.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>rsa_pub_key_path</code></strong> (unicode) - The path to the RSA public key .pem file.</li>
    </ul></dd>
  </dl>
</td></tr></table>
</div>
<a name="load_rsa_priv_key"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">load_rsa_priv_key</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">rsa_priv_key_path</span>,
        <span class="sig-arg">rsa_priv_key_pass</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.load_rsa_priv_key">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Load private RSA key from .pem file.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>rsa_priv_key_path</code></strong> (unicode) - The path to the RSA private key .pem file.</li>
        <li><strong class="pname"><code>rsa_priv_key_pass</code></strong> (unicode) - The RSA private key .pem file password.</li>
    </ul></dd>
  </dl>
</td></tr></table>
</div>
<a name="private_encrypt_text"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">private_encrypt_text</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">plaintext</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_encrypt_text">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Encrypts plaintext with the RSA private key of entity.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>plaintext</code></strong> (str) - The string to be encrypted.</li>
    </ul></dd>
    <dt>Returns: str</dt>
        <dd>The base64 encoded plaintext.</dd>
  </dl>
</td></tr></table>
</div>
<a name="public_encrypt"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">public_encrypt</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">transport</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.public_encrypt">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Encrypts the content of the transport node with public key of 
  recipient.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>transport</code></strong> (unicode) - The &lt;transport/&gt; node content to be encrypted.</li>
    </ul></dd>
    <dt>Returns: tuple</dt>
        <dd>tuple containing: (base64 encrypted transport, base64 encrypted 
          transport-key).</dd>
  </dl>
</td></tr></table>
</div>
<a name="private_decrypt"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">private_decrypt</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">encrypted</span>,
        <span class="sig-arg">transport_key_enc</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_decrypt">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Decrypts a string encoded with public key of recipient.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>encrypted</code></strong> (str) - The base64 encrypted content of the &lt;transport/&gt; node.</li>
        <li><strong class="pname"><code>transport_key_enc</code></strong> (str) - The base64 encrypted transport-key.</li>
    </ul></dd>
    <dt>Returns: str</dt>
        <dd>The decrypted &lt;transport/&gt; node content.</dd>
  </dl>
</td></tr></table>
</div>
<a name="private_sign"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">private_sign</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">content</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.private_sign">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Returns the value of the signature of a the &lt;transport/&gt; node. 
  Reference is OpenSpime protocol v0.9.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>content</code></strong> (str) - The string content of the &lt;transport/&gt; node.</li>
    </ul></dd>
    <dt>Returns: str</dt>
        <dd>The base64 encoded signature of the &lt;transport/&gt; node.</dd>
  </dl>
</td></tr></table>
</div>
<a name="public_check_sign"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">public_check_sign</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">content</span>,
        <span class="sig-arg">signature</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.ssl-pysrc.html#EnDec.public_check_sign">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Returns the value of the signature of a the &lt;transport/&gt; node. 
  Reference is OpenSpime protocol v0.9.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>content</code></strong> (str) - The string content of the &lt;transport/&gt; node.</li>
        <li><strong class="pname"><code>signature</code></strong> (str) - The signature.</li>
    </ul></dd>
    <dt>Returns: boolean</dt>
        <dd>True if signature is valid, False if it is not.</dd>
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pyopenspime/">PyOpenSpime v0.2</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Thu Dec 18 12:31:01 2008
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
